/*
  WET-BOEW
  @title: Form additions to WET-BOEW
 */

%forms-color-red-bold {
	color: #d3080c;
	font-weight: 700;
}

label,
legend,
.checkbox {
	&.required {
		/* Set required asterisk styles... unless any parent element uses a disable class */

		/* Credit: Stack Overflow answer (https://stackoverflow.com/a/73773370) by magda and Zach Jensz (zach-jensz) */
		&:not(.required-no-asterisk .required) {
			&:before {
				@extend %forms-color-red-bold;

				content: "* ";
				margin-left: -$wb-forms-asterisk-width;
				vertical-align: top;
			}
		}

		strong {
			&.required {
				@extend %forms-color-red-bold;
			}
		}
	}
}

.form-group {
	&.has-error {
		.checkbox {
			color: $text-color;
		}
	}

	.checkbox {
		&.checkbox-standalone {
			label {
				font-weight: 700;
			}
		}
	}
}

[dir="rtl"] {
	label,
	legend {
		&.required {
			&:not(.required-no-asterisk .required) {
				&:before {
					margin-left: auto;
					margin-right: -$wb-forms-asterisk-width;
				}
			}
		}
	}
}
